package com.sky.service;

import com.sky.dto.DishDTO;
import com.sky.dto.DishPageQueryDTO;
import com.sky.entity.Dish;
import com.sky.result.PageResult;
import com.sky.vo.DishVO;

import java.util.List;

public interface DishService {


    /**
     * @description: 新增菜品和对应的口味
     * @author: zhouzhijie
     * @date: 2023/11/13 16:41
     * @param: [dishDTO]
     * @return:
     **/
    void saveWithFlavor(DishDTO dishDTO);

    /**
     * @description: 菜品分页查询
     * @author: zhouzhijie
     * @date: 2023/11/15 9:10
     * @param: [dishPageQueryDTO]
     * @return: 
     **/
    PageResult pageQuery(DishPageQueryDTO dishPageQueryDTO);

    /**
     * @description: 菜品批量删除
     * @author: zhouzhijie
     * @date: 2023/11/15 15:37
     * @param: [ids]
     * @return: 
     **/
    void deleteBatch(List<Long> ids);

    /**
     * @description: 根据id查询菜品和对应的口味
     * @author: zhouzhijie
     * @date: 2023/11/15 17:19
     * @param: [id]
     * @return:
     **/
    DishVO getByIdWithFlavor(Long id);

    /**
     * @description: 修改菜品
     * @author: zhouzhijie
     * @date: 2023/11/16 19:15
     * @param: [dishDTO]
     * @return: 
     **/
    void updateWithFlavor(DishDTO dishDTO);

    /**
     * @description: 根据分类id查找菜品
     * @author: zhouzhijie
     * @date: 2023/11/17 9:05
     * @param: [categoryId]
     * @return:
     **/
    List<Dish> list(Long categoryId);

    /**
     * @description: 菜品起售、停售
     * @author: zhouzhijie
     * @date: 2023/11/17 10:20
     * @param: [status, id]
     * @return:
     **/
    void startOrStop(Integer status, Long id);

    /**
     * 条件查询菜品和口味
     * @param dish
     * @return
     */
    List<DishVO> listWithFlavor(Dish dish);
}
